package com.hitqz.robot.biz.controller;

import com.hitqz.robot.common.core.util.R;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author xupkun
 * @date 2024/5/21
 */
@RestController
@AllArgsConstructor
@RequestMapping(value =  {"/auth/"})
@Tag(name = "前端登录器")
@Slf4j
public class AuthController {

    @PostMapping(value = { "/oauth2/token" })
    @Operation (summary = "用户使用前先调用此端口")
    public R token(){
        return R.ok("","操作成功");
    }

    @DeleteMapping(value = "/token/logout")
    @Operation(summary = "退出登陆")
    public R  logout() {

        return R.ok();
    }


}
